//
//  NSTimer+Addition.m
//  FlashFishRec
//
//  Created by zhangcong on 2017/10/11.
//  Copyright © 2017年 zhangcong. All rights reserved.
//

#import "NSTimer+Addition.h"

@implementation NSTimer (Addition)


- (void)pauseTime{
    //判断定时器是否有效
    if (!self.isValid)  {
        return;
    }
    //停止计时器
    [self  setFireDate:[NSDate distantFuture]];
}
- (void)webPageTime{
    //判断定时器是否有效
    if (!self.isValid)  {
        return;
    }
    //返回当期时间
    [self setFireDate:[NSDate date]];
}
- (void)webPageTimeWithTimeInterval:(NSTimeInterval)time{
    //判断定时器是否有效
    if (!self.isValid)  {
        return;
    }
    [self setFireDate:[NSDate dateWithTimeIntervalSinceNow:time]];
}



@end
